package com.qinglei.recoup.system.pojo.event;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

@Data
public class EventDto {

    @ApiModelProperty(value = "事件类型")
    private Integer type;
    @ApiModelProperty(value = "床位号")
    private String bedNo;
    @ApiModelProperty(value = "设备ID")
    private String deviceSn;
    @ApiModelProperty(value = "异常发生时间")
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss")
    private Date happenTime;
    @ApiModelProperty(value = "内容")
    private String content;
    private String uuid;
    private String value;

    public EventDto(Integer type, String bedNo, String deviceSn, Date happenTime, String content) {
        this.type = type;
        this.bedNo = bedNo;
        this.deviceSn = deviceSn;
        this.happenTime = happenTime;
        this.content = content;
    }

    public EventDto(Integer type, String bedNo, String deviceSn, Date happenTime, String content, String value) {
        this.type = type;
        this.bedNo = bedNo;
        this.deviceSn = deviceSn;
        this.happenTime = happenTime;
        this.content = content;
        this.value = value;
    }

    public EventDto() {
    }
}
